Skip to content

feat(ff-serv): add .child() to sync logger for contextual annotations#57

Merged
fdarian merged 5 commits intomainfrom
better-logger-sync
Feb 24, 2026
Merged

feat(ff-serv): add .child() to sync logger for contextual annotations#57
fdarian merged 5 commits intomainfrom
better-logger-sync

Conversation

@fdarian
Copy link
Copy Markdown
Owner

@fdarian fdarian commented Feb 24, 2026

Summary

  • Adds .child() method to the sync logger for creating contextual child loggers
  • Child loggers inherit parent annotations and can add their own, enabling hierarchical annotation composition
  • Exports the SyncLogger type for public API usage
  • Comprehensive test coverage for annotation merging, overrides, and chaining behavior

Test plan

  • Logs without annotations
  • Initial annotations from sync()
  • .child() adds annotations
  • .child() merges parent + child annotations
  • .child() overrides parent on key conflict
  • Chained .child().child() accumulates annotations
  • Parent unaffected by child creation
  • All log levels work on child
  • Per-call attributes merge with persistent annotations

@fdarian fdarian changed the title feat(serv): add .child() to sync logger for contextual annotations feat(ff-serv): add .child() to sync logger for contextual annotations Feb 24, 2026
@fdarian fdarian merged commit 4f104af into main Feb 24, 2026
3 checks passed
@fdarian fdarian deleted the better-logger-sync branch February 24, 2026 04:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant